<div class="slide-dialog-header">
	<div class="slide-dialog-title">
		<h2>{{title}}</h2>
		<div class="slide-dialog-tools">
			<span class="button" ng-class="{'active': data.copyed}" ng-click="copyTable()"><i class="fa fa-toggle-on"></i> 类似创建表结构</span>
		</div>
	</div>
	<div class="slide-dialog-toolbar">
		<ul>
			<li><span class="ui-btn slide-dialog-close" ng-click="close(false)"><i class="fa fa-remove"></i></span></li>
		</ul>
	</div>
</div>
<div class="slide-dialog-body x-slide-dialog-body">
	<form name="form" novalidate="novalidate" ng-submit="submit(form.$valid);">
		<div class="x-data-panel-fixed">
			<div class="x-data-panel-body">
				<div class="x-toolbar">
					<div class="x-query fl">
						<!-- <select name="data.table" ng-if="!data.copyed"><option value="">请选择表</option><option value="1">table</option></select> -->
						<div class="x-select" ng-if="!data.copyed"><input type="text" ng-model="data.table" uib-typeahead="table as table.name for table in tables | filter: {name:$viewValue}" typeahead-min-length="0" typeahead-on-select="selectTable($item, $model, $label, $event)" typeahead-select-on-blur="true" class="x-ipt" placeholder="请选择表" /><span class="x-select-arrow" ng-click="selectAll($event)"><i class="fa fa-caret-down"></i></span></div>
						<span ng-if="data.copyed"><input type="text" name="copyed" ng-model="data.copyedTable" class="x-ipt" placeholder="请输入表名" required /><span class="x-error" ng-if="interacted(form.copyed)" ng-messages="form.copyed.$error"><span ng-message="required">请输入表名</span></span></span>
					</div>
					<div class="fr">
						<button type="button" class="x-btn" ng-click="add()"><i class="fa fa-plus-circle"></i><span class="btn-text">添加字段</span></button>

						<!-- <div class="fr">
							<button type="button" class="x-btn" ng-click="selected()"><span class="btn-text">选择全部</span></button>
						</div> -->
					</div>
				</div>
				<div class="x-grid-fixed x-grid-no-footer" grid-view="gridOptions" grid-selection></div>
			</div>
			<div class="x-data-panel-footer">
				<button class="fl dialog-button cancel-button" type="button" ng-click="prev()">上一步</button><!-- <button class="dialog-button cancel-button" type="button" ng-click="close(false)">取消</button> --><button type="submit" class="dialog-button" ng-disabled="formDisabled"><i class="fa fa-save"></i><span class="btn-text">提交选择</span></button>
			</div>
		</div>
	</form>
</div>